package com.esreport.service;

import com.alibaba.fastjson.JSONObject;
import com.esreport.dto.ArticleInformation;

import java.io.IOException;
import java.text.ParseException;
import java.util.List;

public interface OtherSourceService {

    String getCmsUrl(Integer siteId) throws IOException;

    /**
     * 获取新闻排行
     * @param siteId
     * @param num
     * @param start
     * @param end
     * @return
     * @throws IOException
     * @throws ParseException
     */
    List<ArticleInformation> getTopArticle(Integer siteId, Integer num, String start, String end) throws IOException, ParseException;

    /**
     * 获取新闻详情
     * @param siteId
     * @param articleId
     * @param type
     * @return
     * @throws IOException
     */
    JSONObject getArticleContent(Integer siteId, Integer articleId, String type) throws IOException;

    /**
     * 获取新闻排行 (按发布时间排倒序)
     * @param siteId
     * @param num
     * @return
     */
    List<ArticleInformation> getArticleListOrderByPublishDate(Integer siteId, Integer num) throws IOException;

    /**
     * 党史活动 圈子数据 圈子数， 评论数 ， 点赞数
     * @param siteId
     * @return
     */
    JSONObject getDangShiTopicData(Integer siteId) throws IOException;


}
